﻿<!--#include file="const.inc"-->
<%
'====================================================================
' 感谢使用晴天3G智能建站系统..
' 作者:梁永强.QQ:766750857
' 官方网址:wap.qt3g.com
' 声明:软件版权归作者所有,没有经过作者本人同意不得非法破解和传播本程序
'====================================================================
%>
<%

Set Rs = Server.CreateObject("Adodb.Recordset")
	dim urls,bnid,nid,namer,zf,kongjiana,kongjian,xingbie,nianlin1,meili,tili,renqi,vip,diqu,monery,monery1,mark,touxian,vip1,doing,doingtime
        urls=Request.QueryString("urls")
        bnid=Request("nid")
	if bnid="" then bnid=1
	if not isnumeric(bnid) then bnid=1
	bnid=clng(bnid)
  if urls="" then urls="spacev.asp?nid="&bnid
        	if sid<>"Null" then
                namer=qingtian.name(bnid)
		Sql = "select [id],[zf],[kongjian],[doing],[doingtime],[xingbie],[nianlin],[touxian],[mark],[meili],[money],[money1],[tili],[renqi],[vip],[diqu],[bbs] from [qingtian_user] where [ID]="&bnid&""
		Rs.Open Sql,conn,1,1
		if not (rs.bof and rs.eof)  then
                nid=rs("id")
                zf=rs("zf")
                kongjiana=rs("kongjian")
                doing=rs("doing")
                doingtime=rs("doingtime")
                xingbie=qingtian.utf8(rs("xingbie"))
                nianlin1=rs("nianlin")
                meili=rs("meili")
                tili=rs("tili")
                renqi=rs("renqi")
                touxian=rs("touxian")
                mark=rs("mark")
                vip=rs("vip")
                diqu=qingtian.utf8(rs("diqu"))
                monery=rs("money")
                monery1=rs("money1")
                bbs=rs("bbs")
if bbs then 
bbs="/[站长]"
else
bbs=""
end if

                else
qingtian.err("你访问的会员不存在或已经删除")
                end if
                Rs.close
set rs=nothing
	Set Rs = Server.CreateObject("Adodb.Recordset")
	Sql = "select  [listid] from [qingtian_bbs_bz] where [del]=0 and [nid]="&nid&" order by [id] desc"
	Rs.Open Sql,conn,1,1
	if not (rs.bof and rs.eof) then
bbs=Replace(bbs,"/","")
bbs="/"&bbs&"[版主]"
else
bbs=bbs 
                end if
                Rs.close
set rs=nothing
zft=qingtian.jibie(zf)
select case v
case "0"
we0="<br/>"
hr="-------------------<br/>"
%>
<card title="<%=qingtian.utf8(namer)%>的空间"><p align="<%=qingtian.px%>">
<%
case "1"
hr=""
zi="<span style=""color:#FF5500"">"
zi0="</span>"
we="<div class=""footer"">"
sou="<div class=""block4"">"
dao="<div class=""navi"">"
we0="</div>"
we1="</div>"
%>
<title><%=qingtian.utf8(namer)%>的空间</title>
</head>
<body>
<!--#include virtual="/css.inc"-->
<%

End Select
qingtian.info	
%>		
<%
Set Rs = Server.CreateObject("Adodb.Recordset")
kongjian=qingtian.kongjian
if kongjian="ture" and kongjiana<>true then
%><%=we%>你查看的好友还没开通空间,是否邀请Ta开通?<%=we0%><%=hr%><%=sou%><b><a href="kong.asp?id=<%=bnid%>&amp;act=1&amp;sid=<%=sidd%>">邀请</a>.<a href="<%=qingtian.backurl(urls)%>">不邀请</a>.<a href="kong.asp?id=<%=bnid%>&amp;act=2&amp;sid=<%=sidd%>">帮Ta开通</a></b><%=we0%>
<% 
   else
qingtian.addong("访问了[url=/user/spacev.asp?urls="&urls&"&nid="&nid&"&sid=[sid]]"&namer&"的空间[/url]")
if vip=1 then vip1="<img src=""../img/vip.gif"" alt='VIP' noselect = ""true"" />"
%>
<%=dao%><b><%=qingtian.utf8(namer)%>的空间(ID:<%=qingtian.utf8(nid)%>)-<%=qingtian.onlina(nid)%></b><%=we0%><%=hr%>
<%=sou%>Ta的空间|<a href="UserInfov.Asp?nid=<%=nid%>&amp;sid=<%=sidd%>">详细资料</a><%=we0%><%=we%><%=vip1%><%=xingbie%>/<%=nianlin1%>岁/<%=diqu%>/<%=zft%><%=bbs%><%=we0%><%=sou%><a href="addinfo.asp?bid=<%=nid%>&amp;urls=spacev.asp?nid=<%=nid%>@@urls=<%=urls%>&amp;sid=<%=sidd%>">发消息</a>.<a href="addfans.asp?fansid=<%=nid%>&amp;urls=spacev.asp?nid=<%=bnid%>@@urls=<%=urls%>&amp;sid=<%=sidd%>">加好友</a>.<a href="znaonao.Asp?Action=pay1&amp;fansid=<%=nid%>&amp;sid=<%=sidd%>">挠挠TA</a><br/><a href="chuwu.asp?Act=1&amp;fansid=<%=nid%>&amp;sid=<%=sidd%>">赠礼物</a>.<a href="zqingshu.Asp?Action=pay1&amp;fansid=<%=nid%>&amp;sid=<%=sidd%>">送情书</a>.<a href="myliuyan.Asp?nid=<%=nid%>&amp;sid=<%=sidd%>">发留言</a><%=we0%><%=we%><img src="<%=touxian%>" alt='头像' noselect = "true" /><br/><span style="color:rgb(210,5,5)">个性签名:</span><%=qingtian.ubb2(mark)%><br/><%=hr%><a href="friendt.asp?act=4&amp;sid=<%=sidd%>"><%=qingtian.bi%>(<%=monery%>)</a>.<a href="friendt.asp?act=5&amp;sid=<%=sidd%>">魅力(<%=meili%>)</a>.<a href="friendt.asp?act=6&amp;sid=<%=sidd%>">体力(<%=tili%>)</a>.<a href="friendt.asp?act=3&amp;sid=<%=sidd%>">积分(<%=zf%>)</a>.<a href="friendt.asp?act=7&amp;sid=<%=sidd%>">人气(<%=renqi%>)</a>.<a href="myfdontai.asp?id=<%=nid%>&amp;sid=<%=sidd%>">好友(动态)</a><%=we0%><%=sou%><b>TA的</b>:<a href="mytopic.Asp?id=<%=nid%>&amp;sid=<%=sidd%>">帖子</a>.<a href="myvipic.Asp?id=<%=nid%>&amp;sid=<%=sidd%>">回帖</a>.<a href="/riji/index.Asp?nid=<%=nid%>&amp;sid=<%=sidd%>">日记</a>.<a href="/photo/index.Asp?nid=<%=nid%>&amp;sid=<%=sidd%>">相册</a><%=we0%><%=qingtian.qingsav("304")%>
<%
Sql1 = "select [nameb],[toname],[toid],[bid],[topic],[tos],[totime] from [qingtian_daoju] where aid="&nid&" order by [id] desc"
		Rs.Open Sql1,conn,1,1
		if not (rs.bof and rs.eof) then
%><%=dao%>【<a href="myliwu.Asp?id=<%=nid%>&amp;sid=<%=sidd%>">收到的礼物(<%=rs.RecordCount%>份)</a>】<%=we0%><%=we%>
<%                if rs.RecordCount<3 then
                  For i=1 to rs.RecordCount
%>
<a href="spacev.Asp?nid=<%=rs(3)%>&amp;sid=<%=sidd%>"><%=qingtian.utf8(rs(0))%>(ID:<%=rs(3)%>)</a>:送了Ta<img src="<%=rs(4)%>" alt='' noselect = "true" /><a href="viewdaoju.asp?nid=<%=rs(2)%>&amp;sid=<%=sidd%>"><%=qingtian.utf8(rs(1))%></a><%=rs(5)%>个,<%=qingtian.datatime(now,rs(6))%>前<br/>          
<%   
                        Rs.MoveNext
		 	next
%><a href="myliwu.Asp?id=<%=nid%>&amp;sid=<%=sidd%>">查看Ta更多礼物</a><br/>
<% 
                  else
                  For i=1 to 3
%>
<a href="spacev.Asp?nid=<%=rs(3)%>&amp;sid=<%=sidd%>"><%=qingtian.utf8(rs(0))%>(ID:<%=rs(3)%>)</a>:送了Ta<img src="<%=rs(4)%>" alt='' noselect = "true" /><a href="viewdaoju.asp?nid=<%=rs(2)%>&amp;sid=<%=sidd%>"><%=qingtian.utf8(rs(1))%></a><%=rs(5)%>个,<%=qingtian.datatime(now,rs(6))%>前<br/>            
<%   
                        Rs.MoveNext
		 	next
%><a href="myliwu.Asp?id=<%=nid%>&amp;sid=<%=sidd%>">查看Ta更多礼物</a><br/>
<%                end if
                else
%><%=dao%>【<a href="myliwu.Asp?id=<%=nid%>&amp;sid=<%=sidd%>">收到的礼物(0份)</a>】<%=we0%><%=we%>
Ta还没有收到任何礼物<br/><a href="chuwu.asp?Act=1&amp;fansid=<%=nid%>&amp;sid=<%=sidd%>">送Ta一个礼物</a><br/>
<% 		end if
			Rs.close
                       
Sql1 = "select [nameb],[bid],[bnei],[dotime] from [qingtian_qingshu] where aid="&nid&" order by [id] desc"
		Rs.Open Sql1,conn,1,1
		if not (rs.bof and rs.eof) then

%><%=we1%><%=dao%>【<a href="myqingshu.Asp?id=<%=nid%>&amp;sid=<%=sidd%>">收到的情书(<%=rs.RecordCount%>份)</a>】<%=we0%><%=we%>
<%                if rs.RecordCount<3 then
                  For i=1 to rs.RecordCount
                ne=rs("nameb")
                bidd=rs("bid")
                bnei=left(rs("bnei"),25)&"<a href='myqingshu.Asp?id="&nid&"&amp;sid="&sidd&"'>...</a>"
                dotime=rs("dotime")
tmme="<a href=""spacev.Asp?nid="&bidd&"&amp;sid="&sidd&""">"&ne&"(ID:"&bidd&")</a>"
%>
<%=tmme%>:<%=bnei%>(<%=qingtian.datatime(now,dotime)%>前)<br/>           
<%   
                        Rs.MoveNext
		 	next
%><a href="zqingshu.Asp?Action=pay1&amp;fansid=<%=nid%>&amp;sid=<%=sidd%>">送情书给Ta</a><br/><a href="myqingshu.Asp?id=<%=nid%>&amp;sid=<%=sidd%>">查看Ta更多情书</a><br/>
<% 
                  else
                  For i=1 to 3
                ne=rs("nameb")
                bidd=rs("bid")
                bnei=left(rs("bnei"),25)&"<a href='myqingshu.Asp?id="&nid&"&amp;sid="&sidd&"'>...</a>"
                dotime=rs("dotime")
tmme="<a href=""spacev.Asp?nid="&bidd&"&amp;sid="&sidd&""">"&ne&"(ID:"&bidd&")</a>"
%>
<%=tmme%>:<%=bnei%>(<%=qingtian.datatime(now,dotime)%>前)<br/>            
<%   
                        Rs.MoveNext
		 	next
%><a href="zqingshu.Asp?Action=pay1&amp;fansid=<%=nid%>&amp;sid=<%=sidd%>">送情书给Ta</a><br/><a href="myqingshu.Asp?id=<%=nid%>&amp;sid=<%=sidd%>">查看Ta更多情书</a><br/>
<%                end if
                else
%><%=we1%><%=dao%>【<a href="myqingshu.Asp?id=<%=nid%>&amp;sid=<%=sidd%>">收到的情书(0份)</a>】<%=we0%><%=we%>
好久都没人送情书给Ta了,你要不要<a href="zqingshu.Asp?Action=pay1&amp;fansid=<%=nid%>&amp;sid=<%=sidd%>">送情书给Ta</a><br/>
<% 		end if
			Rs.close
Sql1 = "select [nameb],[bid],[bnei],[dotime] from [qingtian_naonao] where aid="&nid&" order by [id] desc"
		Rs.Open Sql1,conn,1,1
		if not (rs.bof and rs.eof) then

%><%=we1%><%=dao%>【<a href="mynaonao.Asp?id=<%=nid%>&amp;sid=<%=sidd%>">收到的挠挠(<%=rs.RecordCount%>份)</a>】<%=we0%><%=we%>
<%                if rs.RecordCount<3 then
                  For i=1 to rs.RecordCount
                ne=rs("nameb")
                bidd=rs("bid")
                bnei=rs("bnei")
                dotime=rs("dotime")
tmme="<a href=""spacev.asp?nid="&bidd&"&amp;sid="&sidd&""">"&ne&"(ID:"&bidd&")</a>"
tmmr=namer
bnei=Replace(bnei, "B", ""&tmmr&"")
bnei=Replace(bnei, "A", ""&tmme&"")
%>
<%=bnei%>(<%=qingtian.datatime(now,dotime)%>前)<br/>           
<%   
                        Rs.MoveNext
		 	next
%><a href="znaonao.Asp?Action=pay1&amp;fansid=<%=nid%>&amp;sid=<%=sidd%>">挠挠Ta</a><br/><a href="mynaonao.Asp?id=<%=nid%>&amp;sid=<%=sidd%>">查看Ta更多挠挠</a><br/>
<% 
                  else
                  For i=1 to 3
                ne=rs("nameb")
                bidd=rs("bid")
                bnei=rs("bnei")
                dotime=rs("dotime")
tmme="<a href=""spacev.asp?nid="&bidd&"&amp;sid="&sidd&""">"&ne&"(ID:"&bidd&")</a>"
tmmr=namer
bnei=Replace(bnei, "B", ""&tmmr&"")
bnei=Replace(bnei, "A", ""&tmme&"")
%>
<%=bnei%>(<%=qingtian.datatime(now,dotime)%>前)<br/>            
<%   
                        Rs.MoveNext
		 	next
%><a href="znaonao.Asp?Action=pay1&amp;fansid=<%=nid%>&amp;sid=<%=sidd%>">挠挠Ta</a><br/><a href="mynaonao.Asp?id=<%=nid%>&amp;sid=<%=sidd%>">查看Ta更多挠挠</a><br/>
<%                end if
                else
%><%=we1%><%=dao%>【<a href="mynaonao.Asp?id=<%=nid%>&amp;sid=<%=sidd%>">收到的挠挠(0份)</a>】<%=we0%><%=we%>
好久都没人骚扰Ta了,你要不要<a href="znaonao.Asp?Action=pay1&amp;fansid=<%=nid%>&amp;sid=<%=sidd%>">挠挠Ta</a><br/>
<% 		end if
			Rs.close
                     

Sql1 = "select [nameb],[bid],[bnei] from [qingtian_kongjianly] where aid="&nid&" order by [id] desc"
		Rs.Open Sql1,conn,1,1
		if not (rs.bof and rs.eof) then
%><%=we1%><%=dao%>【<a href="myliuyan.Asp?nid=<%=nid%>&amp;sid=<%=sidd%>">空间留言板(<%=rs.RecordCount%>)</a>】<%=we0%><%=we%>
<%                if rs.RecordCount<4 then
                  For i=1 to rs.RecordCount
%>
<a href="spacev.Asp?nid=<%=rs(1)%>&amp;sid=<%=sidd%>"><%=rs(0)%>(ID:<%=rs(1)%>)</a>:<%=qingtian.ubb(left(rs(2),35))%>...<br/>           
<%   
                        Rs.MoveNext
		 	next
%> 
<%=we1%>
<% 
                  else
                  For i=1 to 4
%>
<a href="spacev.Asp?nid=<%=rs(1)%>&amp;sid=<%=sidd%>"><%=rs(0)%>(ID:<%=rs(1)%>)</a>:<%=qingtian.ubb(left(rs(2),35))%>...<br/>           
<%   
                        Rs.MoveNext
		 	next
%>
<%=we1%>
<%                end if
                else
%><%=we1%><%=dao%>【<a href="myliuyan.Asp?sid=<%=sidd%>">空间留言板(0)</a>】<%=we0%><%=we%>
还没有人给Ta留言 , 你会成为第一个哦!<%=we0%>
<% 		end if
			Rs.close
%>
<%if v=0 then %>
	<input emptyok="true"  type="text" name="content<%=RndTXT%>" size="15"/><br/><select title='表情' name='face' value='0'><option title='表情' value='0'>表情</option><option title='微笑' value='1'>微笑</option><option title='哭泣' value='2'>哭泣</option><option title='调皮' value='3'>调皮</option><option title='脸红' value='4'>脸红</option><option title='害羞' value='5'>害羞</option><option title='生气' value='6'>生气</option><option title='偷笑' value='7'>偷笑</option><option title='流汗' value='8'>流汗</option><option title='我倒' value='9'>我倒</option><option title='得意' value='10'>得意</option><option title='奸笑' value='11'>奸笑</option><option title='疑问' value='12'>疑问</option><option title='睡觉' value='13'>睡觉</option><option title='好色' value='14'>好色</option><option title='口水' value='15'>口水</option><option title='敲头' value='16'>敲头</option><option title='惊讶' value='17'>惊讶</option><option title='撇嘴' value='18'>撇嘴</option><option title='难过' value='19'>难过</option><option title='玫瑰' value='20'>玫瑰</option></select>
	<anchor>发表留言
    	<go href="myliuyan.Asp?nid=<%=nid%>&amp;Action=save&amp;sid=<%=sidd%>" method='post'>
        <postfield name="content" value="$(content<%=RndTXT%>)"/>
        <postfield name="face" value="$(face)"/>
    	</go>
	</anchor><br/>
<%else%>
<form action="myliuyan.Asp?nid=<%=nid%>&amp;Action=save&amp;sid=<%=sidd%>" method="post"><%=we%>
<textarea name="content" rows="2"/></textarea><%=we0%><select title='表情' name='face' value='0'><option title='表情' value='0'>表情</option><option title='微笑' value='1'>微笑</option><option title='哭泣' value='2'>哭泣</option><option title='调皮' value='3'>调皮</option><option title='脸红' value='4'>脸红</option><option title='害羞' value='5'>害羞</option><option title='生气' value='6'>生气</option><option title='偷笑' value='7'>偷笑</option><option title='流汗' value='8'>流汗</option><option title='我倒' value='9'>我倒</option><option title='得意' value='10'>得意</option><option title='奸笑' value='11'>奸笑</option><option title='疑问' value='12'>疑问</option><option title='睡觉' value='13'>睡觉</option><option title='好色' value='14'>好色</option><option title='口水' value='15'>口水</option><option title='敲头' value='16'>敲头</option><option title='惊讶' value='17'>惊讶</option><option title='撇嘴' value='18'>撇嘴</option><option title='难过' value='19'>难过</option><option title='玫瑰' value='20'>玫瑰</option></select>
<input type="submit" value="发表留言"/>
</form><br/>
<%end if%>
<%=we%><a href="myliuyan.Asp?nid=<%=nid%>&amp;sid=<%=sidd%>">查看Ta更多留言</a><br/>
<% 
Sql1 = "select * from qingtian_fanke where aid="&nid&" and bid="&qingtian.nid&""
		Rs.Open Sql1,conn,1,3
                if nid<>qingtian.nid() then                
		if (rs.bof and rs.eof) then
                rs.addnew
                rs("namea")=namer
                rs("nameb")=session("username")
                rs("aid")=nid
                rs("bid")=qingtian.nid()
                rs("xinbie")=qingtian.xinbie()
	        rs.update
                else
                rs("dotime")=now()
	        rs.update
                end if
                end if
	        Rs.close                    
Sql1 = "select * from qingtian_fanke where aid="&nid&" and abs(DateDiff('d',dotime,now()))=0"
		Rs.Open Sql1,conn,1,1
		if not (rs.bof and rs.eof) then
                a=rs.RecordCount
                else
                a=0
                end if
	        Rs.close
Sql1 = "select * from qingtian_fanke where aid="&nid&" and abs(DateDiff('d',dotime,now()))=1"
		Rs.Open Sql1,conn,1,1
		if not (rs.bof and rs.eof) then
                b=rs.RecordCount
                else
                b=0
                end if
	        Rs.close
Sql1 = "select [nameb],[bid],[xinbie],[dotime] from [qingtian_fanke] where aid="&nid&" order by [id] desc"
		Rs.Open Sql1,conn,1,1
		if not (rs.bof and rs.eof) then
conn.execute("update qingtian_user set [renqi]="&rs.RecordCount&" where id="&nid&"")
%><%=we1%><%=dao%>【<a href="myfanke.Asp?id=<%=nid%>&amp;sid=<%=sidd%>">最近的访客(<%=rs.RecordCount%>人)</a>】<%=we0%><%=we%>
<%                if rs.RecordCount<4 then
                  For i=1 to rs.RecordCount
%>
<%=qingtian.utf8(rs(2))%>:<a href="spacev.Asp?nid=<%=rs(1)%>&amp;sid=<%=sidd%>"><%=qingtian.utf8(rs(0))%>(ID:<%=rs(1)%>),<%=qingtian.datatime(now,rs(3))%>前</a><br/>       
<%   
                        Rs.MoveNext
		 	next

%><a href="myfanke.Asp?id=<%=nid%>&amp;sid=<%=sidd%>">共<%=rs.RecordCount%>人,昨<%=b%>人,今<%=a%>人</a><br/>
<%
                  else
                  For i=1 to 4
%>
<%=qingtian.utf8(rs(2))%>:<a href="spacev.Asp?nid=<%=rs(1)%>&amp;sid=<%=sidd%>"><%=qingtian.utf8(rs(0))%>(ID:<%=rs(1)%>),<%=qingtian.datatime(now,rs(3))%>前</a><br/>         
<%   
                        Rs.MoveNext
		 	next
%><a href="myfanke.Asp?id=<%=nid%>&amp;sid=<%=sidd%>">共<%=rs.RecordCount%>人,昨日<%=b%>人,今日<%=a%>人</a><br/>
<%                end if
                else
%><%=we1%><%=dao%>【<a href="myfanke.Asp?id=<%=nid%>&amp;sid=<%=sidd%>">最近的访客(0)</a>】<%=we0%><%=we%>
最近还没有人到Ta空间逛过呢!<br/>
<% 		end if
			Rs.close
                        set rs=nothing               
%><%=we1%><%=sou%>TA最近的动态:<br/><%=qingtian.datatime(now,doingtime)%>前TA<%=qingtian.ubb(doing)%><%=we0%>
<%=hr%><%=we%><a href="<%=qingtian.backurl(urls)%>">返回来源页</a><%=we0%>
<% 
end if
else
Response.Redirect "/login.asp?sid=" & sidd & "&url=/user/spacev.asp?nid="&bnid&"@@sid="&sidd&"@@urls="&urls

end if

end Function
%>
